package com.wl.springsecuritystudy.config;

/**
 * jwt的常量
 *
 */
public class ConstantJwt {

    /**
     * jwt 密钥
     */
    public static final String JWT_SIGNING_KEY = "cqbxzc@Jwt!&key^#";

    /**
     * token的http header
     */
    public static final String TOKEN_HTTP_HEADER = "Authorization";

    /**
     * jwt的前缀
     */
    public static final String JWT_TOKEN_PREFIX = "Bearer ";

    /**
     * jwt的主题
     */
    public static final String JWT_SUBJECT = "cqbxzc";

    /**
     * 关键字
     */
    public static final String USER_ID = "userId";

    public static final String USER_CATEGORY = "category";

    public static final String CLIENT_CATEGORY = "client";

    public static final String LAST_REFRESH_TIMESTAMP = "lastRefreshTimestamp";

    /**
     * token过期时间（秒），最后一次刷新后开始计时
     */
    public static final long SESSION_CACHE_TIMEOUT = 7 * 24 * 3600;

}
